<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        .box{
            position: relative;
            width: 300px;
            height: 160px;
            border: 1px solid #000;
        }
        .box>p{
            position: absolute;
            top: 70%;
            left: 40%;
        }
        .box>div{
            width: 30px;
            height: 100px;
            background-color: red;
            float: left;
            margin: 15px;
            border-radius: 20px;
            animation: box 500ms linear 0s infinite alternate;
        }
        .box>div:nth-child(2){
            background-color: green;
            animation-delay: 100ms;
        }
        .box>div:nth-child(3){
            background-color: pink;
            animation-delay: 200ms;
        }
        .box>div:nth-child(4){
            background-color: gold;
            animation-delay: 300ms;
        }
        .box>div:nth-child(5){
            background-color: purple;
            animation-delay: 400ms;
        }
        @keyframes box {
            0%{
                transform: scale(1,1);
            }
            100%{
                transform: scale(1,0.5);
            }
        }
    </style>
</head>
<body>
    <div class="box">
        <div></div>
        <div></div>
        <div></div>
        <div></div>
        <div></div>
        <p>loading...</p>
    </div>
</body>
</html>